<template>
  <div class="parkingManage">
    <el-tabs v-model="activeName" style="height: 100%;" @tab-click="handleClick" type="border-card">
      <el-tab-pane style="height: 100%;" label="泊链停车场" name="second">
        <Tripartite ref="secondMethod" />
      </el-tab-pane>
      <el-tab-pane style="height: 100%;" label="中萌停车场" name="third">
        <CloudParking ref="thirdMethod"/>
      </el-tab-pane>
      <!-- <el-tab-pane label="合作停车场" name="first"><Cooperation ref="firstMethod"/></el-tab-pane> -->
    </el-tabs>
  </div>
</template>

<script>
// import Cooperation from './cooperation/index.vue'
import Tripartite from './tripartite/index.vue'
import CloudParking from './cloudParking/index.vue'

import axios from 'axios'
import qs from 'qs'
export default {
  name: 'ParkingManage',
  components: {
    // Cooperation,
    Tripartite,
    CloudParking
  },
  data() {
    return {
      activeName: 'second'
    }
  },
  mounted() {
    if(location.hash.split("#")[2] != null){
      this.activeName = location.hash.split("#")[2]
    }
  },
  methods: {
    handleClick(tab, event) {
      location.hash = this.$route.path + "#" + tab.name;
    }

  }
}
</script>

<style scoped>
  .parkingManage {
    padding: 8px 20px;
    height: 100%;
    width: 100%;
    position: absolute;
  }
  /deep/ .el-tabs__content{
    height: calc(100% - 50px);
  }
</style>
